﻿using System;
using System.Windows.Forms;

namespace CodeCrawler.UI.Forms.ChildForms
{
    public partial class AddThreat : Form
    {
        public AddThreat()
        {
            InitializeComponent();
        }

        private void AddThreat_Load(object sender, EventArgs e) {
            
            // Start-up Procedure
            populateStrideDefinitions();
            populateSeverity();
        }


        /// <summary>
        /// Populate Severity DropDowns
        /// </summary>
        private void populateSeverity() {
            ui_SeverityDropDown.Items.Add("High");
            ui_SeverityDropDown.Items.Add("Medium");
            ui_SeverityDropDown.Items.Add("Low");
        }


        /// <summary>
        /// Populate DropDowns
        /// </summary>
        private void populateStrideDefinitions() {
            ui_StrideCategoryDropDown.Items.Add("Spoofing");
            ui_StrideCategoryDropDown.Items.Add("Tampering");
            ui_StrideCategoryDropDown.Items.Add("Repudiation");
            ui_StrideCategoryDropDown.Items.Add("Information disclosure");
            ui_StrideCategoryDropDown.Items.Add("Denial of service");
            ui_StrideCategoryDropDown.Items.Add("Elevation of privilege");

            ui_StrideControlDropDown.Items.Add("Authentication");
            ui_StrideControlDropDown.Items.Add("Integrity");
            ui_StrideControlDropDown.Items.Add("Non-Repudiation");
            ui_StrideControlDropDown.Items.Add("Confidentiality");
            ui_StrideControlDropDown.Items.Add("Availability");
            ui_StrideControlDropDown.Items.Add("Other");
        }
    }
}
